clear
capture log close
set more off


*set paths*
gl script   = "[User path]\Countervailing power\Analysis\Scripts"
gl main     = subinstr("$script", "\Scripts", "", .)
gl root     = subinstr("$data", "\Analysis", "", .)

gl data    "$root\Data\Output"
gl output  "$analysis\Output"
gl log     "$analysis\Logs"
gl temp    "$analysis\Temp"

*******************************

*November 25, 2020 
***NOTE: Must run data preparation Stata scripts in "Data" folder prior to running analysis scripts***
do "$script/01 Calculate WTP.do" //Calculates RRT WTP per patient for use in analysis
do "$script/02 Price regressions.do" //Regresses WTP per patient on hospital prices and save output and coefficents
do "$script/03 HHI regressions.do" //Regresses coefficient estiamtes from previous step on insurer HHI
do "$script/04 Tables.do" //Outputs data for all tables
do "$script/05 Figures.do" //Outputs all figures
do "$script/06 Robustness.do" //Regressions of HHI on WTP per patient coefficentts using alternate samples based on insurer and market share (Appendix)

exit
